package com.ruoyi.yl.receptionManage.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.utils.PageUtils;
import com.ruoyi.yl.receptionManage.domain.YlVisitorRegistration;
import com.ruoyi.yl.receptionManage.vo.YlVisitorRegistrationVo;
import com.ruoyi.yl.receptionManage.mapper.YlVisitorRegistrationMapper;
import com.ruoyi.yl.receptionManage.service.IYlVisitorRegistrationService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 来访登记Service业务层处理
 *
 * @author Ming
 * @date 2025-10-21
 */
@Service
public class YlVisitorRegistrationServiceImpl extends ServiceImpl<YlVisitorRegistrationMapper, YlVisitorRegistration> implements IYlVisitorRegistrationService {

    @Override
    public TableDataInfo<YlVisitorRegistrationVo> queryList(YlVisitorRegistrationVo entity) {
        return PageUtils.buildDataInfo(this.baseMapper.queryList(PageUtils.buildPage(), entity));
    }

    @Override
    public List<YlVisitorRegistrationVo> queryAll(YlVisitorRegistrationVo entity) {
        return this.baseMapper.queryList(entity);
    }

    @Override
    public YlVisitorRegistrationVo queryById(Long id) {
        return this.baseMapper.queryById(id);
    }
}
